
#include "page_table.h"

typedef struct procList {
    int processId;
    int processSize;
    PAGE *pageTable;
    struct procList *next;
} PROCESS;


// Initializes a new process list
PROCESS *procListCreate();

// Checks if it's a empty list
bool procListEmpty(PROCESS *processList);

// Link a new element at the end of a process list
bool procListInsert(PROCESS **processList, int processId, int processSize);

// Prints status of process in a list
void procListPrint(PROCESS *processList);

// Find a process page in a processes list
PAGE *pageValid(PROCESS *processList, int processId, int pageNumber);

// Remove a process from a process list
PROCESS *procListRemove(PROCESS **processList, int processId);

// Inserts a new process in a list of increasing processId processes
bool endProcListInsert(PROCESS **processList, PROCESS *endedProcess);
